package com.example.springboot.pojo;

import lombok.Data;
import lombok.ToString;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * @Author:ChenZhangKun
 * @Date: 2022/3/23 15:07
 */
@Component
@PropertySource(value = {"classpath:animal.yaml"})
@ConfigurationProperties(prefix = "animal")
@Data
@ToString
public class Animal {
    private String name;
    private Integer age;
    private boolean boss;
    private Date birth;
    private Map<String, Object> maps;
    private List<String> lists;
    private Dog dog;
}
